home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
BBS Toolkit
/
BBS Toolkit.iso
/
rbbs_pc
/
newz20.zip
/
NEWZ.DOC
< prev
next >
Wrap
Text File
|
1992-06-16
|
9KB
|
260 lines
--> NEWZ Ver 2.1 Copyright (c) 1992 Jim Storch
Newz is an RBBS-PC utility for generating the news files
from user supplied short text files.
I started running a BBS last year and found it very
annoying to try editing my MAIN.NWS and then using an ansi
editor to add color to make MAINC.NWS. I run a non-profit
BBS and didn't want to shell out for a commercial news
generator, plus I wasn't crazy about the ones I saw,
so I wrote my own.
In the spirit of RBBS-PC, I'm releasing this to all sysops
free of charge. This program is not to be sold with the
exception of a reasonable duplication fee, say a buck or
two.
--> Features
News items are quickly generated by simply writing text
files with a specified extension.
Up to 50 news files can be handled at a time.
News items are given a "life" span, you can quickly
create a text to be run from any date to any date.
News items are pre-sorted so that the most recent items are
displayed first.
Your BBS will display "No news items today" when none are found.
Titles and text are automatically centered within a
formatted box simulating computer printout.
Creates both plain text, ibm graphic, and ansi color text files
simultaneously.
Colors and file names are user configurable.
Text files can be optionally deleted by the program
when they are "outdated" by enabling the LICENSED TO KILL
parameter.
EASY EASY EASY To set up, run and use!
--> How it works
Probably the easiest way to explain the program is to
describe the configuration file. This is a normal text
file consisting of nine lines. Here they are, one at a
time
LINE 1
This line contains the complete path and file name of
the plain text file used by RBBS-PC for system news,
normally MAIN.NWS.
example:
C:\RBBS\TEXT\MAIN.NWS
LINE 2
Almost identical as line 1, except this is the complete
path and file name of the ansi-color text file used for
system news, normally MAINC.NWS
You can specify whatever paths and filenames you like, but
for simplicity, these two files will be referred to as
MAIN & MAINC from here on.
example:
C:\RBBS\TEXT\MAINC.NWS
LINE 3
Again, this is the path/filename of the IBM graphic char
news file to create, normally maing.nws
example:
C:\RBBS\TEXT\MAIN.NWS
LINE 4
This is the complete path, wildcard character (*.) and extension
for the news item text files you will create. I use an extension
of NWZ to keep it simple, but you can specify whatever extension
you like.
example:
C:\RBBS\NEWS\*.NWZ
NOTE1 You must include the full path, even if the news files are
in the same directory as the program.
NOTE2 You must use the asterisk character inside the line. The
program uses it to parse the path and extension.
NOTE3 If you decide you'd like to use the same extension as
MAIN and MAINC remember to keep them in separate directories.
Else, the program will try to open them as news item and you may
destroy time and space as we know it, (more likely, it would
read the start and stops dates for both file as 0/0/000AD).
NOTE4 You can use "*.*" for a wildcard if the only files
in the specified directory are news items. This way you don't
even have to use an extension.
LINE 5
This is a nice feature called LICENSED TO KILL. If this line
reads "YES" the program is allowed to delete all new items
that are beyond their stop dates. This allows you to
fire-and-forget your news text files. If the line is set to
anything else, old news items will be retained, but
not included in MAIN/MAINC.
LINE 6
This is the Ansi-color string that will be used for the
"print-out" BORDER around each news item in the MAINC file.
Later in this text will be a listing of ansi-color strings and
how to use them.
LINE 7
This is the Ansi-color string for the TITLE of the news item.
LINE 8 This is the Ansi-color string for the TEXT of the news item.
LINE9 This is the Ansi-color string for "normal". This line is added
to the end of each news item, so that if a user ABORT's after the
first couple items it wont leave the system with strange colored
text. It also allows you to "type mainc.nws". Set this to whatever
you use for normal, i.e. non-bold white on black.
--> Using Newz
If you're a sysop, you've obviously found a text editor
of choice. Be sure to use a TEXT EDITOR and not a word
processor that adds strange formatting characters.
Simply create your news files with the following
format:
Line1: start date month/day/year
Line2: stop date month/day/year
Line3: Title
Line4 -LineX: Text of message. Be sure to keep each line
under 70 characters to keep room for the border.
EXAMPLE:
10/31/1991
11/30/1991
NEW CONFERENCES!
The BBS now features 5 new discussion topics.
1) Sysops who hate their Users.
2) Users who hate their Sysops.
3) Artificial Intelligence
4) C++ Programming
5) Komodo Dragons
Next, simply run NEWZxx.EXE. (But, before you do, edit the
NEWZ.CFG file). The program will take this text file and
(if the dates are current) generate a plain text MAIN.NWS
and ansi color MAINC.NWS.
That's all there is to it. You can create up to 50 news text
files at a time, and NEWZ will include the ones it need.
If the program (1) finds no news item files or (2) finds files,
but none are current for today, it will create a one line MAIN
and MAINC saying "No news items today." The MAINC version
will use the ansi-color selected for TITLE and end with
the ansi-color for NORMAL
If you add this program to you RBBS-1TM.BAT (or whatever batch
file you use for periotic maintenance), and enable the
license-to-kill feature, you will have a fully automated
news generator that you can add items to in seconds.
--> Format of Ansi color strings
(From page 595 of MS-DOS 5.0 User's guide and reference)
Text Attributes To enter a string just
0 All attributes off seperate numbers with a
1 Bold on (Bright) semi-colon
5 Blink on
7 Reverse Video on the following example sets
a bright great border with
Foreground colors a flashing, bright red title
30 Black and bright blue text, all on
31 Red a black background.
32 Green
33 Yellow 0;1;32;40 (BORDER)
34 Blue 5;1;31;40 (TITLE)
35 Magenta 1;34;40 (TEXT)
36 Cyan 0;37;40 (set to normal,
37 White white on black).
Background Color
40 Black
41 Red
42 Green
43 Yellow
44 Blue
45 Magenta
46 Cyan
47 White
If you are curious, ansi-color strings begin with "ESC[" and end
with a lowercase "m". The program automatically adds these to the
strings in NEWZ.CFG.
--> Lastly
If you have any problems or suggestions about NEWZ,
please drop me a line at
ELECTRIC HARBOR BBS
(703) 730-0542
Jim Storch
3317 Esquarre CT
Woodbridge, Va
22193
Changes for 2.0
You can now enter dates as 10/21/92 or 10/21/1992. Before you
had to use a four digit year, but this messed some people up.
Fixed a major bug where it would just create the border for the
news items but leave the body blank. This took me forever to track
down and, as expected, was a stupid and obvious mistake in my code.
Support for plain old ascii callers. In my first version, I only
had IBM char and color main.nws files. Now, I create all three.
This was prompted when I found I had callers with commodore 64's
using the doors.
News items are centered a hair better on the screen.
QUOTE, quote of the day utilty added. See quote.doc.
2.1
License to Kill was botched! Now works.